package com.xpgk.xpsoft.log;

import com.jfinal.kit.Kv;
import com.xpgk.common.controller.BaseController;
import com.xpgk.common.kit.PubKit;

public class LogController extends BaseController {

	public void index() {
		render("index.html");
	}

	public void pagingData() {
		Kv cond = Kv.by("L.NAME = ", getPara("name", ""));
		cond.set("U.USERNAME = ", getPara("userName", ""));
		cond.set("L.Lx1 = ", getPara("type1", " ").equals(" ") ? "" : getPara("type1"));
		cond.set(" L.IP = ", getPara("ip", ""));
		cond.set("L.GXSJ >= ", (PubKit.toDate(getPara("beginTime", PubKit.Date()), null)));
		cond.set("L.GXSJ <= ", PubKit.toDate(getPara("endTime"), null));
		String data = paging("xpSoftParam.findLogList", Kv.by("cond", cond));
		renderJson(data);
	}

}
